networking

您所在的位置:网站首页 kali network is unreachable networking

networking

2023-09-11 16:04| 来源: 网络整理| 查看: 265

Archlinux says, try dhcpcd in case your installer can't connect automatically. This worked on the spot for me AFTER installation. Just type "dhcpcd" as a command, wait a few seconds, and then "ip route" or "ping 8.8.8.8" to check if it works. I even used "watch ip address" to see how fast these inet and inet6 addresses pop up.

Instead of using dhcpcd, I can also connect from zero with:

modprobe e1000e ip link set dev eth0 up ip address add 192.168.0.16/24 dev eth0 ip route add 192.168.0.0/24 dev eth0 ip route add default via 192.168.0.1

e1000e is a "Network Driver", says modinfo. By loading this module I get a eth0 link (no, don't look for it in /dev). The "ip" commands activate the link, choose an address and define a local (subnet) and then a default gateway. It took me quite some time to test this out (ip link help, ip address help, ip route help...).

So this is instructive, but "dhcpcd" is faster to type, and probably more robust. And you can stop it cleanly with "dhcpcd -x".

With a working ping and the mirrorlist in /etc/pacman.d/ you have all you need for pacman or pacstrap.

And yes, I saw a kernel message renaming eth0 to enoxxx, so you have to check first with "ip link" what interfaces are already set up by systemd. It happens here:

[ 3.052354] e1000e 0000:00:1f.6 eth0: (PCI Express:2.5GT/s:Width x1) 94:c6:91:a5:39:b8 [ 3.052360] e1000e 0000:00:1f.6 eth0: Intel(R) PRO/1000 Network Connection [ 3.052445] e1000e 0000:00:1f.6 eth0: MAC: 13, PHY: 12, PBA No: FFFFFF-0FF [ 3.055917] e1000e 0000:00:1f.6 eno1: renamed from eth0

The .16 in my address is just any (free) number, and 192.168.0.1 should always be the gateway. Maybe I was lucky, but it is good news that you can hack around under systemd and inet6. I will try netctl, though.

And right now I have booted with systemd and have dhcpcd started. I got address .15 on "eno1" and three inet6 addresses, but apart from that the result is quite the same as with above "ip"-hack.

3: eno1: mtu 1500 qdisc fq_codel state UP group default qlen 1000 link/ether 94:c6:91:a5:39:b8 brd ff:ff:ff:ff:ff:ff inet 192.168.0.15/24 brd 192.168.0.255 scope global noprefixroute eno1 valid_lft forever preferred_lft forever inet6 2a05:41c0:12:bf00::2/128 scope global dynamic noprefixroute valid_lft 2559430sec preferred_lft 572230sec inet6 2a05:41c0:12:bf00:f51e:97c1:de6f:6f49/64 scope global dynamic mngtmpaddr noprefixroute valid_lft 2591994sec preferred_lft 604794sec inet6 fe80::47cf:a2e4:af0b:b7cd/64 scope link valid_lft forever preferred_lft forever default via 192.168.0.1 dev eno1 proto dhcp src 192.168.0.15 metric 203 192.168.0.0/24 dev eno1 proto dhcp scope link src 192.168.0.15 metric 203


【本文地址】


今日新闻


推荐新闻


CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3